<template>
    <div>
        <!-- 获取路由参数$route.params -->
        <!-- 获取查询字符串参数$route.query -->
        order页面- {{ $route.params.username }}-{{ $route.params.age }}
        <div>
            邮箱：{{ $route.query.email }} - {{ $route.query.id }}
        </div>

    </div>
</template>

<script setup>
import { onMounted } from 'vue';
import { useRoute } from 'vue-router';
const route = useRoute()

onMounted(() => {
    console.log(route.params)
    console.log(route.query)
})

</script>

<style lang="scss" scoped></style>